/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Negocios;

import java.io.*;
import java.util.logging.Level;
import java.util.logging.Logger;
import Gestores.XMLLeer;

/**
 *
 * @author radxt
 */
public class ValidacionPass {
        XMLLeer reader = new XMLLeer("nuevo.xml");
        
    public int DevolverPass(String login) {
        return this.reader.devolverPass(login);
    }

    public boolean ValidarUser(String login, String password) {
        Integer hashed = password.hashCode();
        return (hashed == DevolverPass(login));
    }
    
    public int DevolverGrupo(String login){
        return this.reader.devolverGrupo(login);
    }
    
    public int DevolverCodigo(String login){
        return this.reader.devolverCodigo(login);
    }
    public String DevolverNombre(String id){
        return this.reader.devolverNombre(id);
    }
   
}